
package org.abc;


import java.util.Date;
import java.util.Scanner;

public class V1 {
    int i = 16; //属性 成员属性 成员变量 会自动的初始化
    final int y = 100;
    final static double PI = 3.1415926;

    public static void main(String[] args) {
        final int a = 10;
        System.out.println(PI);
        Scanner sc = new Scanner(System.in);
        System.out.println();
        System.out.println(Math.PI);




        System.out.println(a);
        System.out.println(a*2);

        //局部变量，必须初始化才可以使用

        var age = 3;


        //var 在java10 新增的 主要用来声明变量时根据值类型推断
        //var ss = "ok";
        //var sdf = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
        //List<Map<String,Object>> list = new ArrayList<>();

        {
            String ok = "hello";
        }
        //System.out.println(ok);

        System.out.println(age * 2);

        System.out.println(age * 6);

        System.out.println(age * 9);

        String sname = "李四";
        System.out.println("欢迎："+sname);

        Date d = new Date();
    }
}
